﻿using System.Collections.Generic;
using Missbot.Service;

namespace Missbot.AIModule.Record
{
    public class HelloRecord : DbBaseEntity
    {
        public string GroupID { get; init; }
        public string UserID { get; init; }
        public string Content { get; set; }
    }

    public static class HelloRecordDA
    {
        public static List<HelloRecord> GetAll()
        {
            return MongoService<HelloRecord>.Get();
        }

        public static void Update(this HelloRecord entity)
        {
            MongoService<HelloRecord>.Update(entity);
        }

        public static void Insert(this HelloRecord entity)
        {
            MongoService<HelloRecord>.Insert(entity);
        }

        public static void Remove(this HelloRecord entity)
        {
            MongoService<HelloRecord>.Delete(entity);
        }
    }
}